Component({
  options: {
    multipleSlots: true
  },
  properties: {
    hasBtn: {
      type: Boolean,
      value: true
    },
    showMore: {
      type: true,
      value: false
    }
  },
  data: {
    activeNames: [],
    show: false
  },
  methods: {
    onChange(e) {
      this.setData({
        activeNames: e.detail
      })
    },
    search() {
      this.setData({
        show: false
      });
      this.triggerEvent('search')
    },
    reset() {
      this.setData({
        show: false
      });
      this.triggerEvent('reset')
    },
    close() {
      this.setData({
        show: false
      });
      this.triggerEvent('close');
    },
    show() {
      this.setData({
        show: true
      });
      this.triggerEvent('show');
    }
  }
});
